<template>
  <div class="biaoqiandaohang" v-if="module.modules.length">
    <div class="hot-search">
      <div class="recently-search-text">热门搜索</div>
      <div class="recently-search-item-view flex-x">
        <div
          class="recently-search-item flex-x-0-center"
          :class="item.pic ? 'recently-search-item-pic':''"
          v-for="item in module.modules"
          :key="item.id"
        >
          <img
            :src="fileBaseUrl + item.pic"
            v-if="item.pic"
            style="width:16px; height:16px"
          />
          <span>{{ item.title }}</span>
        </div>
      </div>
    </div>
  </div>
  <ModuleNotConfig :module="module" v-else />
</template>

<script>
export default {
  props: {
    module: {
      type: Object,
    },
    fileBaseUrl: {
      type: String,
    },
  },
};
</script>

<style lang="scss" scoped>
.recently-search-text {
  font-size: 14.5px;
  font-weight: bold;
  color: black;
}

.recently-search-item-view {
  flex-wrap: wrap;
  padding: 0px 5px;
}

.recently-search-item {
  margin-top: 16px;
  margin-right: 16.5px;
  font-size: 13.5px;
  padding: 9px 14.5px;
  font-weight: 400;
  color: #363535;
  background: #f6f6f6;
  border-radius: 15px;
}

.recently-search-item img {
  width: 16px;
  height: 16px;
  margin-right: 5px;
}

.recently-search-item span {
  white-space: nowrap;
}

.item-active {
  font-size: 13.5px;
  font-family: PingFang SC;
  font-weight: 400;
  color: #fb481f;
}

.hot-search {
  padding-top: 12.5px;
}

.recently-search-item-pic {
  padding-left: 10px;
}
</style>